package com.enterpriseDigitalPlatform.util;

import org.apache.commons.lang3.StringUtils;

public class RequiredCheckUtil {
    // 必填参数校验空值
    private RequiredCheckUtil() {
    }

    // Integer 校验空值
    public static boolean checkInt(Integer obj) {
        return obj == null || obj == 0;
    }

    // String 校验空值
    public static boolean checkString(String obj) {
        return StringUtils.isEmpty(obj);
    }

    // Long 校验空值
    public static boolean checkLong(Long obj) {
        return obj == null || obj == 0;
    }

    public static boolean checkDouble(Double obj) {
        return obj == null || obj == 0;
    }
}
